package com.wenson.structural.decorator;

import java.io.BufferedInputStream;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.util.zip.ZipInputStream;

/**
 * @ClassName: DecoratorClient
 * @Author: luowangcheng
 * @Date: 2024/6/14 7:01
 * @Description:
 */
public class DecoratorClient {
    public static void main(String[] args) throws FileNotFoundException {
        //用装饰器包裹女孩后再展示
        Showable madeupGirl = new Lipstick(new FoundationMakeup(new Girl()));
        madeupGirl.show();

        //运行结果：涂口红【打粉底【女生的脸庞】】
        File file = new File("/压缩包.zip");
        // 开始装饰
        ZipInputStream zipInputStream = new ZipInputStream(
                new BufferedInputStream(
                        new FileInputStream(file)
                )
        );
    }
}
